package com.googlecode.gwtbb.client.shared.util;

/**
 * Used for instead of assert for things that are required for correct operation.
 *
 * @author Abraham Grief
 * @version $Id$
 * @since Aug 7, 2008
 */
public class Ensure {
	public static void isTrue(boolean val) {
		isTrue(val, "Ensure.isTrue failed");
	}

	public static void isTrue(boolean val, String failureMsg) {
		if (!val)
			throw new EnsureException(failureMsg);
	}

	private Ensure() {
	}
}
